package com.atguigu.factory.fruit;

/**
 * @author xgc
 * @create 2021-07-22 11:43
 */
public class FruitApp {
    public static void main(String[] args) {
        FruitFactory fruitFactory = new FruitFactory();
        Apple apple = (Apple) fruitFactory.createFruit("apple");
        Pear pear = (Pear)fruitFactory.createFruit("pear");
        apple.whatIm();
    }
}
